projects
/
babl.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
0f66bde
)
babl: check both source/dest bits/component in bad_idea()
author
Øyvind Kolås
<pippin@gimp.org>
Mon, 25 Sep 2017 19:00:08 +0000
(21:00 +0200)
committer
Øyvind Kolås
<pippin@gimp.org>
Mon, 25 Sep 2017 19:00:08 +0000
(21:00 +0200)
babl/babl-fish-path.c
patch
|
blob
|
history
diff --git
a/babl/babl-fish-path.c
b/babl/babl-fish-path.c
index 6b2874bd2a88d1beeb4a459bb6fe842e392fb48a..2a71464b9b608ea1896f39ec1da487d9e2ea87a3 100644
(file)
--- a/
babl/babl-fish-path.c
+++ b/
babl/babl-fish-path.c
@@
-165,7
+165,8
@@
bad_idea (const Babl *from, const Babl *to, const Babl *format)
{
return 1;
}
- if (from->format.type[0]->bits > format->format.type[0]->bits)
+ if (from->format.type[0]->bits > format->format.type[0]->bits &&
+ to->format.type[0]->bits > format->format.type[0]->bits)
{
/* XXX: perhaps we especially avoid going to half-float, when
* going between u16 formats as well? */